/*
 * @Author: zhaiyujia
 * @Date: 2022-11-16 00:43:31
 * @LastEditors: zhaiyujia
 * @LastEditTime: 2022-11-19 00:32:40
 * @Description: uart test.
 */

#include "Arduino.h"

void setup()
{
    Serial_begin(115200);
    delay(1500); // Wait for STC-ISP to open the serial port
    Serial_println("Hello Arduino-STC.");
}
void loop()
{
    Serial_println("---------------");
    Serial_println(itoa(0x888, BIN));
    Serial_println(itoa(0x888, HEX));
    Serial_println(itoa(0x888, DEC));
    Serial_println(itoa(888, DEC));
    Serial_println(itoa(-888, DEC));
    Serial_println(itoa(atoi("888"), DEC));
    Serial_println(itoa(atoi("-888"), DEC));
    Serial_println(itoa(atoi("888") + 1, DEC));
    Serial_println(itoa(atoi("888") - 1, DEC));
    Serial_println(itoa(atoi("888") + 999, DEC));
    Serial_println(itoa(atoi("888") - 999, DEC));
    delay(1000);
}